package com.example.gitresp.pojo;

import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@Data
@NoArgsConstructor
@AllArgsConstructor
public class Result {
    private Integer i;
    private String msg;
    private Object data;
    public static Result success(Object data){
        //有响应数据的
       return new Result(1,"成功",data);
    }
    public static Result success(){
        //有响应数据的
       return new Result(1,"成功",null);
    }
    public static Result error(){
        return new Result(0,"失败",null);
    }
}
